package xyj.sparrow.client.service;


import xyj.sparrow.common.netty.bean.Result;

/**
 * @author 江南小俊
 * @since 2021/6/16
 **/
public abstract class ITask {
    protected abstract Result<String> run(String[] args);

    public final Result<String> start(String taskId, String[] args) {
        Result<String> result = run(args);
        result.setData(taskId);
        return result;
    }
}
